package com.easychat.entity.enums;

public enum AppUpdateStatusEnum {
    INIT(0, "未发布"),
    GRAYSCALE(1, "灰度发布"),
    ALL(2, "全网发布");

    private Integer type;
    private String description;

    AppUpdateStatusEnum(Integer type, String description) {
        this.type = type;
        this.description = description;
    }

    public Integer getType() {
        return type;
    }

    public String getDescription() {
        return description;
    }

    public static AppUpdateStatusEnum getByType(Integer type) {
        for (AppUpdateStatusEnum appUpdateStatusEnum : AppUpdateStatusEnum.values()) {
            if (appUpdateStatusEnum.type.equals(type)) {
                return appUpdateStatusEnum;
            }
        }
        return null;

    }
}
